package com.hehe.boot.controller;

import com.hehe.boot.pojo.Admin;
import com.hehe.boot.pojo.User;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@CrossOrigin(origins = "*")
public class HelloController {
    @ApiOperation("hello world 控制器")
    @GetMapping(value = "/hello")
    public String HelloWorld(){
        return "hello world";
    }

    @GetMapping(value = "/user")
    public Admin user(@ApiParam("用户名") String username){

        return new Admin();
    }
}
